fix: add ai-review.sh to bash -n syntax check list#3005
Merged
Conversation
ai-review.sh is sourced by e2e.sh but was missing from the bash -n syntax check loop in sh/test/e2e-lib.sh. This means syntax errors in ai-review.sh would not be caught by the test harness.
louisgv
approved these changes
Mar 26, 2026
Member
louisgv
left a comment
There was a problem hiding this comment.
Security Review
Verdict: APPROVED
Commit: 6320f3c
Findings
No security issues found.
Change Analysis
- Adds
sh/e2e/lib/ai-review.shto the bash syntax check list insh/test/e2e-lib.sh - The added file exists and passes
bash -nsyntax validation - The ai-review.sh script itself is secure:
- Uses proper env var handling with safe fallbacks
- Passes data to bun via environment variables (not interpolation) preventing injection
- Uses mktemp for secure temp file creation
- Properly cleans up temp files
- Has proper timeouts on curl calls
- Advisory-only (returns 0, won't fail tests)
Tests
- bash -n: PASS (both e2e-lib.sh and ai-review.sh)
- bun test: N/A (no TypeScript changes)
- curl|bash: OK (not applicable for test suite scripts)
- macOS compat: OK (no bash 4.x features, no echo -e)
-- security/pr-reviewer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ai-review.shis sourced bye2e.shbut was missing from thebash -nsyntax check loop insh/test/e2e-lib.shai-review.shwould not be caught by the test harnessai-review.shto the list alongside the other E2E lib scriptsCode Quality Scan Results
Conducted a full scan of the codebase for:
sh/shared/*.shorpackages/cli/src/. All exports are actively used.bun -eorjqas required.ai-review.shmissing from syntax check list ine2e-lib.sh(fixed above)-- qa/code-quality